import request from '@/utils/request'
// 查询消息列表
export function messageList(query) {
    return request({
        url: '/messageCenter/messageInfo/list',
        method: 'get',
        params: query
    })
}
export function messageTypeList(query) {
    return request({
        url: '/messageCenter/messageParam/list',
        method: 'get',
        params: query
    })
}
export function messageNoticeList(query) {
    return request({
        url: '/messageCenter/messageConfig/list',
        method: 'get',
        params: query
    })
}
export function messageCount(query) {
    return request({
        url: '/messageCenter/messageInfo/selectMessageCount',
        method: 'get',
        params: query
    })
}
// 查询通知详情
export function messageCountDetail(Id) {
    return request({
        url: `/messageCenter/messageConfig/${Id}`,
        method: 'get'
    })
}
// 查询列表详情
export function messageListDetail(Id) {
    return request({
        url: `/messageCenter/messageInfo/${Id}`,
        method: 'get'
    })
}
// 消息参数编辑
export function messageCountUpdate(data) {
    return request({
        url: '/messageCenter/messageConfig',
        method: 'put',
        data: data
    })
}
// 消息通知编辑
export function messageNoticeUpdate(data) {
    return request({
        url: '/messageCenter/messageConfig/editTemplate',
        method: 'post',
        data: data
    })
}
// 消息新增
export function messageCountAdd(data) {
    return request({
        url: '/messageCenter/messageConfig',
        method: 'post',
        data: data
    })
}
// 重新发送
export function messageCountAgae(Id) {
    return request({
        url: `/messageCenter/messageInfo/resend`,
        method: 'get',
        params: Id
    })
}
// 获取消息通知路由
export function messageRouterGet(params) {
    return request({
        url: `/messageCenter/messageInfo/getRouteParams`,
        method: 'get',
        params: params
    })
}
// 消息状态更新
export function messageUpdate(data) {
    return request({
        url: '/messageCenter/messageInfo',
        method: 'put',
        data: data
    })
}
// 获取消息通知路由
export function getNoticePersion(params) {
    return request({
        url: `/system/user/userPostList`,
        method: 'get',
        params: params
    })
}
